home *** CD-ROM | disk | FTP | other *** search
/ ETO Development Tools 1 / ETO Development Tools 1.iso / Essentials / MacApp Documentation / MacApp AppleLink Messages / MacApp.Tech$ 12⁄8⁄89 / 0178-Re Failures & Initia-Dec89 < prev    next >
Encoding:
Text File  |  1989-12-08  |  971 b   |  29 lines  |  [TEXT/GEOL]

  1. Item    6606979                         7-Dec-89        08:35
  2.  
  3. From:   ALGER                           Alger, Jeff,VCA
  4.  
  5. To:     D1950                           CSG, Don Phillips,PRT
  6.  
  7. cc:     MACAPP.TECH$                    MacApp Technical
  8.  
  9. Sub:    Re: Failures & Initialization
  10.  
  11. Jo-Ann,
  12.  
  13. Geoff's observations are accurate - your code is correct as written for failure
  14. handling.  I thought perhaps that your confusion might stem from a common
  15. misperception when first using failure handlers: in your code, if IObject2
  16. fails, the line
  17.  
  18.    SELF.ffObjRef := tmpObjRef;
  19.  
  20. will never be reached.  Instead, your failure handler for IObject1 will be
  21. called immediately after the failure handler for IObject2, which will then
  22. percolate upwards (unless you take pains to do otherwise) until control can be
  23. once again turned over to the idle loop of MacApp.  The invalid handle stored
  24. in tmpObjRef will never be used to initialize ffObjRef.
  25.  
  26. Jeff Alger
  27. KPMG Peat Marwick
  28.  
  29.